package com.example.library.dao;

import com.example.library.bean.model.Book;
import com.example.library.bean.model.BookType;
import org.springframework.data.jpa.repository.JpaRepository;

import java.util.List;

public interface BookRepository extends JpaRepository<Book,Long> {

    List<Book> findAllByType(BookType type);

    Book findByBookId(long bookId);

    List<Book> findAllByBookNameContainsOrAuthorContainsOrPublisherContains(String bookName,String author,String publisher);
}
